package com.qtest.qandroid.service.UserServiceImp;

import com.qtest.qandroid.dao.HomeworkDao;
import com.qtest.qandroid.entity.AttendanceJob;
import com.qtest.qandroid.entity.Homework;
import com.qtest.qandroid.service.HomeworkService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class HomeworkServiceimpl implements HomeworkService {
    @Autowired
    private HomeworkDao homeworkDao;

    @Override
    public Boolean addHomework(Homework homework) {
        if (homeworkDao.addHomework(homework))
            return true;
        else return false;
    }

    @Override
    public List<Homework> allHomework(String courseId) {
        return homeworkDao.allHomework(courseId);
    }
}
